import request from '@/utils/request'

// 获取树
export function getTree(data) {
  return request({
    url: 'common/type/treeselect',
    method: 'post',
    data:data
  })
}


// 获取部门树
export function getdeptTree() {
  return request({
    url: 'system/user/deptTree',
    method: 'get',
  })
}


//查询项目管理列表
export function getTableData(query) {
  return request({
    url: '/common/project/list',
    method: 'get',
    params: query
  })
}

//查询参检人员列表
export function getPeopleData(query) {
  return request({
    url: '/system/user/list',
    method: 'get',
    params: query
  })
}

//查询参检人员列表
export function addPeopleData(query) {
  return request({
    url: '/enter/enter/insert',
    method: 'POST',
    data: query
  })
}

//公司检查项目新增
export function addExamine(query) {
  return request({
    url: '/enterCheckProject/enterCheckProject',
    method: 'POST',
    data: query
  })
}

//公司检查项目查看
export function getExamine(id) {
  return request({
    url: '/enterCheckProject/enterCheckProject/'+id,
    method: 'get',

  })
}

//公司检查项目修改
export function reviseExamine(query) {
  return request({
    url: '/enterCheckProject/enterCheckProject',
    method: 'PUT',
    data: query
  })
}

//公司检查项目删除
export function delExamine(id) {
  return request({
    url: '/enterCheckProject/enterCheckProject/'+id,
    method: 'DELETE',
  })
}